package com.fz.us.admin.company.dao;



import com.fz.us.admin.base.dao.BaseDao;
import com.fz.us.admin.company.bean.FlowEnum;
import com.fz.us.admin.company.entity.TaskEntity;
import com.fz.us.admin.company.entity.User;

import java.util.List;

/**
 *
 * ============================================================================
 * 版权所有 2013 。
 * 
 * @author 
 * @version 0.1 2013-1-16
 * ============================================================================
 */

public interface TaskEntityDao extends BaseDao<TaskEntity, String> {

    public List<TaskEntity> getInfoByEntityName(String entityName);

    public TaskEntity getInfoByKeyId(String keyId);

    public List<TaskEntity> getInfoByReaders(String entityName, FlowEnum.ProcessState[] processState, String user_id);

    /**
     * 获得当前用户的草稿
     * @return
     */
    public List<TaskEntity> getInfoByDraft(FlowEnum.ProcessState processState, User user);

    /**
     * 根据当前用户的编辑权限查数据
     * @param processState
     * @param user_id
     * @return
     */
    public List<TaskEntity> getInfoByEditors(FlowEnum.ProcessState[] processState, String user_id);

}